1. Field of the Invention
The present invention relates to a database system that is accessed by an application program that executes a specific operation, and relates in particular to a database system that can flexibly cope with an addition to or a change in the application contents or in relationships among data.
2. Description of the Related Art
Since an application program that executes a specific operation handles a large amount of data, normally, such data are stored and managed by a database system. This database system is generally constructed as follows. First, databases (also called entities) required for all the application programs, and data entries for the pertinent databases (also called attributes of the individual entities) are obtained. Then, the relationship between the databases (the hierarchical structure, such as a parent-child relationship) and the relationship between the data entries for each database are defined or determined, so that processing can be efficiently performed by all possible application programs. These relationships that are determined can be represented as an ER diagram (Entity Relationship diagram). An ER diagram is defined as an actual database for which the function of a database management system (DBMS) is used. For example, a relational database is defined using a language such as SQL. As a result, in each database, relationship data (e.g., a pointer) pointing to a record identifier for a related database is generated in a record (a key area or a column) in which the actual values and the contents (instances) of individual data are stored. Actually, the relationship data (e.g., pointers) tend to be generated by an application program as a part of a normal application.
When the contents of an application are changed or a new application is added, or when a database is added or changed, the relationship/hierarchical structure of the databases is modified accordingly (for example, the parent-child relationship is canceled/added/reversed). In this case, an alteration operation must be performed by which the databases are again related with each other in the above described manner, and the obtained hierarchical structure is stored in a database using the function for the database management system (DBMS). Further, relationship data, such as pointers, that are present in a record (column) in each conventional database must be changed. Specifically, a program for changing the database is prepared, and is then used to alter the database.
When such a change is made, all the application programs that employ the modified database (which read and process data entries, or which write and update data) must be examined to confirm that the contents have been changed in accordance with the hierarchical structure of the database, and that the modification has had no adverse affect. As a part of a normal application, a process could be performed by which, while there is no change in the relationship of the databases, i.e., in the database hierarchical structure, the relationship of a record in a database to a record in another related database would be changed (e.g., a parent-child relationship or a positional relationship is modified at a so-called instance level, such as a case wherein a client A gives a specific telephone number to another person). An application program will handle this change process.
For a specific application program, the relationship and the hierarchical structure required for the processing are present in a group of databases that are employed by the program. Since this relationship/hierarchical structure constitutes a part (a subset) of the relationship existing among all the databases, a different relationship/hierarchical structure for the pertinent application program need not be prepared. That is, by navigating through those relationship data, such as pointers, that represent the relationship among all the databases, a required database can be reached. However, while taking working efficiency into account, the relationship/hierarchical structure of a pertinent application program is normally prepared using a function of the database management system (DBMS) called the view function. Using this function, an application program can access a pertinent database group by referring to the view.
When an operational database used for applications is viewed in another way, generally, the actual value/contents (instances) of the latest data are stored in individual records in each database, and only the latest data can be employed. The “latest” here is a value (results of a nighttime batch process) obtained when a nighttime process was completed for the preceding day, or the latest state (results of a real time process) obtained by adding/updating data each time a transaction occurs. When an application program performs a process for each specific period, for example, when an application program totals at the end of a month the records stored during that month, the pertinent application program accesses the database at the end of the pertinent month and performs a predetermined process based on all the latest data records that are stored in the database. However, a case exists wherein the relationship among databases or data records is changed at a specific time in the middle of a month (e.g., a case wherein the parent-child relationship (or belonging relationship) is changed at a so-called instance level, such as when client A gives (actually, sells) a specific telephone number to another person). In this case, data representing the period during which the pertinent relationship was effective are not included in conventional relationship data (e.g., a pointer). As a result, when the change of the relationship occurs, the pertinent application program must be temporarily initiated based on the latest recorded data and the relationship data, and at the end of the month in which the relationship was changed, that application program must again be executed based on the latest recorded data, i.e., the changed data and the relationship data.